import { Injectable } from '@angular/core';
import { HttpClientService } from '../../../services/http-client.service';

@Injectable()
export class CheckService {

  constructor(
    public httpClient: HttpClientService
  ) { }
  // 查询企业年金审核列表
  list(getBody) {
    return this.httpClient.get('/pms/v1/pension/pensionAudit/listAuditPage', getBody);
  }
  // 审核通过
  checkPass(nFundNoList, sAuditNoList) {
    let putBody: any = {
      "nFundNoList": nFundNoList,
      "sAuditNoList": sAuditNoList,
      "auditStatus": "2"
    }
    return this.httpClient.put('/pms/v1/pension/pensionAudit/updateRevisionReview' + '?sFundType=4', putBody);
  }
  // 审核不通过
  checkNotPass(nFundNoList, sAuditNoList) {
    let putBody: any = {
      "nFundNoList": nFundNoList,
      "sAuditNoList": sAuditNoList,
      "auditStatus": "3"
    }
    return this.httpClient.put('/pms/v1/pension/pensionAudit/updateRevisionReview' + '?sFundType=4', putBody);
  }
  //撤回
  checkWithdrew(sAuditNo) {
    return this.httpClient.put('/pms/v1/pension/pensionAudit/updateAuditState' + '?sAuditNo=' + sAuditNo + '&auditStatus=4');
  }
}
